(function() {

	var NParser = com.googlecode.restitory.gae.xml.XMLParser;
	
	XMLParserEntry = function(item) {
		this.nitem = item;
	}
	XMLParser = function(parser) {
		if(!parser) {
			return null;
		}
		this.parser = parser;
		this.length = parser.length;
		for(var i = 0; i < parser.length; i++) {
			var entry = new XMLParser();
			entry.parser = parser.item(i);
			entry.content = '' + entry.parser.content;
			this[i] = entry;
		}
		this.content = '' + parser.content;
	}
	XMLParser.prototype.find = function(xpath) {
		var nret = this.parser.find(xpath);
		var ret = new XMLParser(nret);
		return ret;
	}
	
	XMLParser.parse = function(xml) {
		var parser = NParser.parse(xml);
		var ret = new XMLParser(parser);
		return ret;
	}
	
})();
